package com.xncoding.freemarker;

import com.xncoding.starter.inter.EnableReading;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ApplicationListener;
import org.springframework.context.event.ContextClosedEvent;

@SpringBootApplication
@EnableReading
public class SpringbootFreemarkerApplication implements ApplicationListener<ContextClosedEvent> {

	public static void main(String[] args) {
		SpringApplication.run(SpringbootFreemarkerApplication.class, args);
	}

	@Override
	public void onApplicationEvent(ContextClosedEvent contextClosedEvent) {
		System.out.println("SpringbootFreemarkerApplication.onApplicationEvent");
		System.exit(0);
	}
}
